package com.project.bean;


import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * 销售详情
 * （销售详情编号，成交价，销售数量，库存商品外键，库存商品对象，销售信息外键）
 */
@Data
@ApiModel(value = "销售详情")
@TableName("t_selldetail")
public class SellDetailBean {
    @ApiModelProperty(hidden = true)
    @TableId(value = "pk_sellDetailId",type = IdType.AUTO)
    private Integer id;
    @ApiModelProperty(value = "成交价")
    @TableField("d_sellPrice")
    private Integer price;//成交价
    @ApiModelProperty(value = "销售数量")
    @TableField("d_num")
    private Integer num;//销售数量
    @ApiModelProperty(value = "库存商品外键")
    @TableField("fk_goodsId")
    private String fk_goodsId;//库存商品外键
    @ApiModelProperty(value = "销售信息外键")
    @TableField("fk_sellOrderId")
    private Integer fk_sellOrderId;//销售信息外键
    @ApiModelProperty(value = "库存商品对象")
    @TableField(exist = false)
    private GoodsBean goodsBean;//库存商品对象

    public SellDetailBean() {
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getPrice() {
        return price;
    }

    public void setPrice(Integer price) {
        this.price = price;
    }

    public Integer getNum() {
        return num;
    }

    public void setNum(Integer num) {
        this.num = num;
    }

    public String getFk_goodsId() {
        return fk_goodsId;
    }

    public void setFk_goodsId(String fk_goodsId) {
        this.fk_goodsId = fk_goodsId;
    }

    public Integer getFk_sellOrderId() {
        return fk_sellOrderId;
    }

    public void setFk_sellOrderId(Integer fk_sellOrderId) {
        this.fk_sellOrderId = fk_sellOrderId;
    }

    public GoodsBean getGoodsBean() {
        return goodsBean;
    }

    public void setGoodsBean(GoodsBean goodsBean) {
        this.goodsBean = goodsBean;
    }

    @Override
    public String toString() {
        return "SellDetailBean{" +
                "id=" + id +
                ", price=" + price +
                ", num=" + num +
                ", fk_goodsId='" + fk_goodsId + '\'' +
                ", fk_sellOrderId=" + fk_sellOrderId +
                ", goodsBean=" + goodsBean +
                '}';
    }
}
